package com.zsrt.oa.ticket.dao;

import java.sql.SQLException;
import java.util.List;

import com.zsrt.oa.ticket.entity.TicketEntity;

/**
 * 门票的持久层接口
 * @author 罗智壕-13424431416
 *
 * 2017年6月9日
 */
public interface TicketDao {
	
	/**
	 * 门票的增加
	 * @param entity
	 * @return
	 */
	int ticketAdd(TicketEntity entity)  throws SQLException;
	
	/**
	 * 门票的查询
	 * @param start 从第几条开始
	 * @param end 到第几条结束
	 * @return
	 * @throws SQLException
	 */
	List<TicketEntity> ticketQuery(Integer start,Integer end) throws SQLException;
	
	/**
	 * 根据id指定查询
	 * @param ticketId
	 * @return
	 * @throws SQLException
	 */
	List<TicketEntity> ticketByFindId(Integer ticketId) throws SQLException;
	
	/**
	 * 门票修改
	 * @param entity
	 * @return
	 * @throws SQLException
	 */
	int ticketUpdate(TicketEntity entity) throws SQLException;
	
	/**
	 * 删除门票
	 * @param ticketId
	 * @return
	 * @throws SQLException
	 */
	int ticketDelete(Integer ticketId) throws SQLException;
}
